<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		
		<script>
			// 1.==比较:会进行隐式转换,再进行比较
			var num1 = 123;
			var num2 = "123";
			
			// == 判断,隐式转换:将string转成number
			console.log(num1 == num2);
			
			var flag1 = true;
			var flag2 = "true";
			// 隐式转换:都转成number再比较,
			// flag1 -> 1
			// flag2 -> 2
			console.log(flag1 == flag2);//false
			
			// 2.===全等:类型相等,数据相等(更多)
			console.log(num1 === num2);
			
			// 2.!=比较:隐式转换
			// 2.!==比较:不会进行隐式转换0
			console.log(num1 != num2);//false
			console.log(num1 !== num2);//true
		</script>
	</body>
</html>
